import 'package:ride_rex/main/home/landmark_bean.dart';

import '../article/comment.dart';
import '../main/discover/discover_bean.dart';

abstract class DbInterface {
  ///打开数据库
  Future openDb();

  ///关闭数据库
  Future closeDb();

  ///存地标数据
  Future<List<LandmarkBean>> getLandmarkData();

  ///修改地标解锁状态
  Future updateLandmark(LandmarkBean bean);

  ///查询已解锁的地标
  Future<int> getUnlockedLandmarkCount();

  ///点赞
  Future like({required String recordId});

  ///取消点赞
  Future cancelLike({required String recordId});

  ///是否已点赞
  Future<bool> isLike({required String recordId});

  ///添加评论（需要绑定作品id，作品所属作者的id）
  Future addComment({required CommentBean bean, required String workId});

  ///获取评论列表
  Future<List<CommentBean>> getCommentList({required String workId});

  ///获取用户列表
  Future<List<FeedUserBean>> getLocalUserList({String? userId});

  ///存用户列表
  Future saveUserList(List<FeedUserBean> userList);

  ///关注、取消关注用户
  Future followUser({required String userId, required String isFollow});

  ///拉黑、取消拉黑用户
  Future blockUser({required String userId, required String isBlock});
}
